package cs3343.project.family;


/**
 * The Class MapController.
 */
public class MapController {

	
	/** The map dimension. */
	private int mapDimension;
	
	/** The map size. */
	private int mapSize;
	
	/**
	 * Sets the up map.
	 *
	 * @param noOfPlayers the new up map
	 */
	public void setupMap(int noOfPlayers) {
		if (noOfPlayers <= 2) {
			mapDimension = 6;
		}
		else if (noOfPlayers > 2 && noOfPlayers <= 4) {
			mapDimension = 8;
		}
		else {
			mapDimension = 10;
		}
		
		mapSize = (mapDimension + 4) * 2 - 1;
	}

	/**
	 * Gets the map dimension.
	 *
	 * @return the map dimension
	 */
	public int getMapDimension() {
		return mapDimension;
	}

	/**
	 * Sets the map dimension.
	 *
	 * @param mapDimension the new map dimension
	 */
	public void setMapDimension(int mapDimension) {
		this.mapDimension = mapDimension;
	}

	/**
	 * Gets the map size.
	 *
	 * @return the map size
	 */
	public int getMapSize() {
		return mapSize;
	}

	/**
	 * Sets the map size.
	 *
	 * @param mapSize the new map size
	 */
	public void setMapSize(int mapSize) {
		this.mapSize = mapSize;
	}
}
